import axios from '../axios/index.js'
//获取全部素材
export const allMaterial = ({ collect, page, per_page }) => {
    return axios.get('/mp/v1_0/user/images', {
        params: {
            collect,
            page,
            per_page
        }
    })
}
//删除图片素材
export const delePic = (target) => {
    return axios.delete(`/mp/v1_0/user/images/${target}`)
}
//收藏 or 取消收藏图片素材
export const collectPic = (target, collect) => {
    return axios.put(`/mp/v1_0/user/images/${target}`, {
        collect
    })
}